/*
 * @FilePath     : /jquery/routes/jq-ajax.js
 * @Description  : 路由-jq-ajax
 * @Date         : 2025-03-20 15:34
 * @Author       : Fang YingGui
 * @LastEditors  : fangyinggui 18715384437@163.com
 * @LastEditTime : 2025-03-20 20:19
 */
const express = require('express')

const router = express.Router()

// 根路径
router.get('/', function (req, res) {
  res.send('ajax get /')
})

// statusCode 选项路由
router.get('/statusCode', function (req, res) {
  res.status(404).send('ajax get /statusCode 404')
})

//  获取请求数据
router.post('/bostom', function (req, res) {
  console.log(req.body)
  res.send('获取客户端传递来的数据')
})

module.exports = router
